<%--
  Created by IntelliJ IDEA.
  User: owner
  Date: 2018-08-05
  Time: 22:12
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" pageEncoding="UTF-8" isELIgnored="false" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
<%@include file="../../include/back/BackHeader.jsp"%>
<%@include file="../../include/back/BackNavigator.jsp"%>
<title>订单管理</title>
<div class="Back_orderlist">
    <span class="label label-info Back_orderlist_tab">分类信息</span>
    <span hidden <c:if test="${!empty param.delete}"> class="nodelete" </c:if> id="deleteSpan">
    </span>
    <table class="table table-bordered table-hover table-striped table-condensed Back_orderlist_table">
        <thead>
        <tr>
            <th>ID</th>
            <th>状态</th>
            <th>金额</th>
            <th>商品数量</th>
            <th>买家名称</th>
            <th>创建时间</th>
            <th>支付时间</th>
            <th>发货时间</th>
            <th>确认收货时间</th>
            <th>操作</th>
        </tr>
        </thead>
        <tbody>
        <c:forEach items="${orders}" var="ord" varStatus="st">
            <tr>
                <td class="myorder_id">${ord.id}</td>
                <td>${ord.statusDesc}</td>
                <td>${ord.total}</td>
                <td>${ord.totalNumber}</td>
                <td>${ord.user.name}</td>
                <td><c:if test="${!empty ord.createDateDesc}"> ${ord.createDateDesc}</c:if></td>
                <td><c:if test="${!empty ord.payDateDesc}"> ${ord.payDateDesc}</c:if></td>
                <td><c:if test="${!empty ord.deliveryDateDesc}"> ${ord.deliveryDateDesc}</c:if></td>
                <td><c:if test="${!empty ord.confirmDateDesc}"> ${ord.confirmDateDesc}</c:if></td>
                <%--<td>${ord.payDateDesc}</td>--%>
                <%--<td>${ord.deliveryDateDesc}</td>--%>
                <%--<td>${ord.confirmDateDesc}</td>--%>
                <td>
                        <button class="btn btn-primary orderItem" id="item_${ord.id}">查看详情</button>
                    <c:if test="${fn:contains(ord.status,'waitDelivery' )}">
                        <a href="admin_order_delivery?id=${ord.id}"><button class="btn btn-primary delivery" id="delivery_${ord.id}">发货</button></a>
                    </c:if>
                </td>
            </tr>
        </c:forEach>
        </tbody>
    </table>
</div>
<%@include file="../../include/back/BackPage.jsp"%>
<%@include file="../../include/back/BackFooter.jsp"%>



